package com.tbit.main.service.impl;

import cn.hutool.core.collection.CollUtil;
import com.tbit.main.dao.log.RefundOrderDao;
import com.tbit.main.pojo.RefundOrder;
import com.tbit.main.service.RefundOrderService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.Collections;
import java.util.List;

/**
 * @author <a href="mailto:li.yao@tbit.com.cn">yao</a>
 * @version 4.2.0
 * @since 2024/10/21 15:22
 */
@Service
public class RefundOrderServiceImpl implements RefundOrderService {

    @Resource
    private RefundOrderDao refundOrderDao;

    @Override
    public List<RefundOrder> getByBusinessNo(String businessNo) {
        return refundOrderDao.getByBusinessNo(businessNo);
    }

    @Override
    public List<RefundOrder> getByBusinessNos(List<String> businessNos) {
        return CollUtil.isNotEmpty(businessNos)
                ? refundOrderDao.getByBusinessNos(businessNos)
                : Collections.emptyList();
    }
}
